package com.fzsf.drawingboard.bluetooth.hypen;

import android.bluetooth.BluetoothDevice;

import com.fzsf.drawingboard.app.MyApplication;
import com.fzsf.drawingboard.bluetooth.FZWritingPadConstant;
import com.fzsf.drawingboard.bluetooth.IFZWritingPad;
import com.fzsf.drawingboard.bluetooth.IFZWritingPadCallBackListener;


/**
 * Created by Taijl on 2017/9/18.
 */

public class FZWritingPad_Hypen implements IFZWritingPad {

    @Override
    public void scanDevice() {
        FZWritingPad_HypenHelper.getInstance().scan();
    }

    @Override
    public void connectDevice(BluetoothDevice device) {
        FZWritingPad_HypenHelper.getInstance().connect(MyApplication.getInstance(), device.getAddress());
    }

    @Override
    public void connectDeviceByName(String deviceName) {

    }

    @Override
    public boolean getConnectState() {
        return FZWritingPad_HypenHelper.getInstance().getConnectState();
    }

    @Override
    public void switchWorkMode(int workMode) {
        FZWritingPad_HypenHelper.getInstance().switchWorkMode(workMode);
    }

    @Override
    public void disConnect() {
        FZWritingPad_HypenHelper.getInstance().disConnect();
    }

    @Override
    public void setFZWritingPadCallBackListener(IFZWritingPadCallBackListener listener) {
        FZWritingPad_HypenHelper.getInstance().setFZWritingPadCallBackListener(listener);
    }

    @Override
    public int getDefinitePadType() {
        return FZWritingPadConstant.FZWritingPadType.TYPE_HYPEN;
    }
}
